package com.tx.apimember.service;

import com.tx.memberdto.out.dto.UserOutDTO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import com.tx.base.BaseResponse;
/***
 * @Author Sunny
 * @Description //TODO  会员服务接口
 * @Date 11:14 2019/9/17
 * @Param
 * @return
 */
@Api(tags = "会员服务接口")
public interface MemberService {

    /**
     * 根据手机号码查询是否已经存在,如果存在返回当前用户信息
     *
     * @param mobile
     * @return
     */
    @ApiOperation(value = "根据手机号码查询是否已经存在")
    @ApiImplicitParams({
            @ApiImplicitParam(paramType = "query", name = "mobile", dataType = "String", required = true, value = "用户手机号码"), })
    @GetMapping("/existMobile")
    BaseResponse<UserOutDTO> existMobile(@RequestParam("mobile") String mobile);


    /**
     * 根据token查询用户信息
     *
     * @param userEntity
     * @return
     */
    @GetMapping("/getUserInfo")
    @ApiOperation(value = "根据Toke查询是否已经存在")
    BaseResponse<UserOutDTO> getInfo(@RequestParam("token") String token);
}

